import axios from 'axios';
import {apiPath} from "./apiPath";

const baseUrl = apiPath.archiveList;

export interface Article {
    id: number;
    title: string;
    titleImage: string;
    createData: string;
    createMonth: string;
}

export interface ArchiveData {
    month: any;
    articles: Article[];
}

export const getArchiveList = async (data: any) => {
    const res = await axios.post(baseUrl, data);
    return res.data.data;
}
